Skip to content

AI: Add a rate limiter with complete implementation and add it to necessary routes#1

Open
VELUVOLU-DEEPAK wants to merge 1 commit intoJagjeevanAK:mainfrom
VELUVOLU-DEEPAK:feat/add-rate-limiter-complete-mnjfxs
Open

AI: Add a rate limiter with complete implementation and add it to necessary routes#1
VELUVOLU-DEEPAK wants to merge 1 commit intoJagjeevanAK:mainfrom
VELUVOLU-DEEPAK:feat/add-rate-limiter-complete-mnjfxs

Conversation

@VELUVOLU-DEEPAK
Copy link

Implemented a rate limiter using 'express-rate-limit' by creating a new utility file rateLimiter.ts. A general API rate limiter is applied to all backend routes via routes/index.ts, and a stricter rate limiter is applied to sensitive authentication routes (/register, /login) in routes/auth.routes.ts to mitigate brute-force attacks. The main index.ts file was updated to include standard Express setup and mount the API router, ensuring the rate limiters are active.

…ecessary routes

Code validated successfully (1 iteration)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant